package com.livegoods.pojo;

import lombok.Data;
import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

@Data
@Document(indexName = "house_index",type = "house_type",shards =5,replicas = 1)
public class HouseES {


    @Id
    private String id;

    @Field(type = FieldType.Text,analyzer = "ik_max_word")
    private String title;

    @Field(type = FieldType.Text,analyzer = "ik_max_word")
    private String houseType;

    @Field(type = FieldType.Keyword)
    private String price;

    @Field(type = FieldType.Keyword)
    private String img;


    @Field(type = FieldType.Keyword)
    private String rentType;


    @Field(type = FieldType.Keyword)
    private String city;

//    id: Math.random().toString().slice(2),
//    title: "豪宅 · 使馆壹号院4居室-南",
//    houseType: "17/19层| 4室1厅 - 273.97 ㎡",
//    price: "<h3>130000</h3>",
//    rentType: "整租",
//    img: "http://iwenwiki.com/api/livable/search/1.jpg"

}
